<!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<ui:composition xmlns="http://www.w3.org/1999/xhtml"
                xmlns:ui="http://java.sun.com/jsf/facelets"
                xmlns:h="http://java.sun.com/jsf/html"
                xmlns:f="http://java.sun.com/jsf/core"
                xmlns:c="http://java.sun.com/jstl/core"
                xmlns:sf="http://www.springframework.org/tags/faces"
                xmlns:a4j="http://richfaces.org/a4j"
                xmlns:rich="http://richfaces.org/rich"
                xmlns:spring="http://www.springframework.org/tags"
                template="../../../layout/Template.xhtml">

    <ui:define name="menu">
        <ui:include src="${user.menu}"/>
    </ui:define>

    <ui:define name="title">
        <h:outputText value="#{resourceBundle.deleteRegistrationWelcome}"/>
    </ui:define>

    <ui:define name="footer">
        <h:outputText
                value="SPiJ - Universite de Marne la Vallee - Version 1.0"/>
    </ui:define>

    <ui:define name="content">
        <ui:fragment id="deleteRegistrationFragment">
            <h:form id="deleteRegistrationForm">
                <h:outputText
                        value="#{bundle.deleteMessageInformation} 'N°#{flowScope.currentRegistration.id}'?"/>
                <rich:panel id="deleteLessonPanel"
                            header="#{resourceBundle.deleteRegistrationOverview}">

                    <h:panelGrid id="deleteLessonGrid" columns="2">
                        <h:outputText
                                value="#{resourceBundle.deleteRegistrationStudent} : "/>
                        <h:outputText value="#{flowScope.currentRegistration.student}"/>

                        <h:outputText value="#{resourceBundle.deleteRegistrationTraining} : "/>
                        <h:outputText value="#{flowScope.currentRegistration.training}"/>
                        <h:outputText
                                value="#{resourceBundle.deleteRegistrationStartTime} : "/>
                        <h:outputText value="#{flowScope.currentRegistration.startTime}">
                            <f:convertDateTime pattern="MM/yyyy" type="time"/>
                        </h:outputText>

                        <h:outputText value="#{resourceBundle.deleteRegistrationEndTime} : "/>
                        <h:outputText value="#{flowScope.currentRegistration.endTime}">
                            <f:convertDateTime pattern="MM/yyyy" type="time"/>
                        </h:outputText>
                    </h:panelGrid>
                </rich:panel>
                <a4j:commandButton id="deleteRegistrationButtonDelete"
                                   value="#{bundle.Yes}" action="delete"/>
                <a4j:commandButton id="deleteRegistrationButtonCancel"
                                   value="#{bundle.No}" action="cancel"/>

            </h:form>
        </ui:fragment>
    </ui:define>

</ui:composition>